package com.zhitong.money.converters;



import com.zhitong.money.util.DateUtil;
import org.springframework.core.convert.converter.Converter;
import org.springframework.stereotype.Component;

import java.util.Date;

@Component
public class DateConverter implements Converter<String, Date> {

    @Override
    public Date convert(String s) {
        Date date = DateUtil.StrToDate(s,DateUtil.FORMAT1);
        return date;
    }
}
